Skip to content

feat(research): distinguish win rate, payoff and Profit Factor - #668

Merged
Pigbibi merged 1 commit into
mainfrom
codex/unified-outcome-metric-standard
Oct 13, 2026
Merged

Pigbibi merged 1 commit into
mainfrom
codex/unified-outcome-metric-standard

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

The unified research report has growth/risk/inference metrics but does not expose win rate, mean payoff, Profit Factor or arithmetic net expectancy. Existing window win_rate and profit_factor describe daily returns; Profit Factor is not average payoff, and neither is a closed-trade statistic.

Add four optional, descriptive net period-return diagnostics via include_outcome_diagnostics=True: excluding-zero win rate, mean gain/loss payoff, aggregate gain/loss Profit Factor and sample mean net return. Report positive/negative/zero counts and explicit observation-level semantics. Undefined one-sided samples and unrepresentable values retain UNCOMPUTABLE/null; genuine exact zero remains known. Default output preserves the original eight results. No trade pairing is inferred.

Add a linked bilingual metric catalog describing return/benchmark, risk-adjusted return, drawdown/tails, outcomes, statistical reliability, cost/execution, portfolio/capacity and operations/source evidence, with actual capability and missing-input boundaries. Clarify payoff versus Profit Factor in the existing window/backtest docs. No new pass/fail thresholds, ranking roles or permissions are introduced.

Validation: 13 analytic synthetic regressions pass; original unified-report and lifecycle golden tests pass (50 focused cases). Independent review found and reproduced nonzero float underflow being reported as zero; corrected and rechecked, with eight base/default compatibility scenarios unchanged. CONTRIBUTING full unittest completed 1366 cases / one existing skip. Local first-run failures were missing the existing required monitor source-revision environment; reproduced on the unmodified base and resolved by binding the real checked-out base SHA, without test/source weakening. Ruff, whitespace and document links pass. Final head aab4083 passed CI38356900706: 2563 passed / 2 existing skipped / 1013 subtests passed, Ruff and constraint-ref checks passed. Normal merge b23511c has the identical reviewed tree bdd500aca5033cb800335e5445ad7282e6d696b1; no branch protection bypass. Main automatic CI is tracked separately.

Refs QuantStrategyLab/QuantRuntimeSettings#659 and QuantStrategyLab/QuantInternalOps#3. Closed-trade metrics, actual costs/source attestation, drawdown recovery/capacity/live execution projections and consumer adoption remain separate. No production pin, sizing, gate, strategy trial/ledger, posterior model, account, budget, live order or notification is changed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant